<?php
class Zendvn_Filter_Link implements Zend_Filter_Interface{
	
	public function filter($value){
		$filter = new Zend_Filter();
        $filter->addFilter(new Zend_Filter_StringToLower(array('encoding'=>'utf-8')))
				->addFilter(new Zendvn_Filter_Utf8())
				->addFilter(new Zend_Filter_StringTrim())
				->addFilter(new Zend_Filter_Alnum(true))
				->addFilter(new Zend_Filter_PregReplace('#\s+#','-'));
		return $filter->filter($value);
	}
}